-- GENERATED SPELL FOR [Firebrand Darkweaver] --


function spell0_9261(pUnit, Event) --@Curse of the Firebrand,n/a--
pUnit:FullCastSpellOnTarget(16071,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9261', 2000, 1)
end

function spell1_9261(pUnit, Event) --@Dispel Magic,n/a--
pUnit:FullCastSpellOnTarget(15090,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9261', 654, 1)
end

function spell2_9261(pUnit, Event) --@Mark of Flames,n/a--
pUnit:FullCastSpellOnTarget(15128,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9261', 1000, 1)
end

function spell3_9261(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(12471,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9261', 3000, 1)
end

function spell4_9261(pUnit, Event) --@Shadow Bolt Volley,n/a--
pUnit:FullCastSpellOnTarget(14887,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9261', 3000, 1)
end

function Sorts_9261(pUnit, Event)
local choix_sorts_9261 = math.random(0, 4)
if choix_sorts_9261 == 0 then
pUnit:RegisterEvent('spell0_9261', 1, 1)
end
if choix_sorts_9261 == 1 then
pUnit:RegisterEvent('spell1_9261', 1, 1)
end
if choix_sorts_9261 == 2 then
pUnit:RegisterEvent('spell2_9261', 1, 1)
end
if choix_sorts_9261 == 3 then
pUnit:RegisterEvent('spell3_9261', 1, 1)
end
if choix_sorts_9261 == 4 then
pUnit:RegisterEvent('spell4_9261', 1, 1)
end
end

function mob9261_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_9261', math.random(1500, 3000), 1)
end

function mob9261_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob9261_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob9261_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(9261, 1, 'mob9261_Action')
RegisterUnitEvent(9261, 2, 'mob9261_Leave')
RegisterUnitEvent(9261, 3, 'mob9261_Kill')
RegisterUnitEvent(9261, 4, 'mob9261_Die')
